package com.itqf.ipmsys.service.impl;

import com.itqf.ipmsys.vo.DailyIncomeVO;
import com.itqf.ipmsys.vo.ParkingLotsVO;
import com.itqf.ipmsys.entity.Destrict;
import com.itqf.ipmsys.mapper.DestrictMapper;
import com.itqf.ipmsys.service.DestrictService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>
 * 县区表 服务实现类
 * </p>
 *
 * @author corn
 * @since 2021-09-22
 */
@Service
public class DestrictServiceImpl extends ServiceImpl<DestrictMapper, Destrict> implements DestrictService {

    @Resource
    private DestrictMapper destrictMapper;

    /**
     * 查找停车区域分布图
     *
     * @return
     */
    @Override
    public List<ParkingLotsVO> findIsConnectedParkingLots() {
        List<ParkingLotsVO> parkingLots =  destrictMapper.selectIsConnectedParkingLots();
        return parkingLots;
    }

    /**
     * 停车场今日区域消费图
     *
     * @return
     */
    @Override
    public List<DailyIncomeVO> findDailyIncome() {
        List<DailyIncomeVO> dailyIncomeDTOList = destrictMapper.selectDailyIncome();
        return dailyIncomeDTOList;
    }
}
